package com.liqi.items.service;

import com.liqi.items.domain.TCfgService;
import com.liqi.items.domain.TRelFormSubject;
import com.liqi.items.domain.TRelServiceSubject;

import java.util.List;
import java.util.Map;

/**
 * 主题事项关联Service接口
 *
 * @author xiaoli
 * @date 2022-04-08
 */
public interface ITRelServiceSubjectService
{
    /**
     * 查询主题事项关联
     *
     * @param id 主题事项关联主键
     * @return 主题事项关联
     */
    public TRelServiceSubject selectTRelServiceSubjectById(Long id);

    /**
     * 查询主题事项关联列表
     *
     * @param tRelServiceSubject 主题事项关联
     * @return 主题事项关联集合
     */
    public List<TRelServiceSubject> selectTRelServiceSubjectList(TRelServiceSubject tRelServiceSubject);

    /**
     * 新增主题事项关联
     *
     * @param tRelServiceSubject 主题事项关联
     * @return 结果
     */
    public int insertTRelServiceSubject(TRelServiceSubject tRelServiceSubject);

    /**
     * 修改主题事项关联
     *
     * @param tRelServiceSubject 主题事项关联
     * @return 结果
     */
    public int updateTRelServiceSubject(TRelServiceSubject tRelServiceSubject);

    /**
     * 批量删除主题事项关联
     *
     * @param ids 需要删除的主题事项关联主键集合
     * @return 结果
     */
    public int deleteTRelServiceSubjectByIds(Long[] ids);

    /**
     * 删除主题事项关联信息
     *
     * @param id 主题事项关联主键
     * @return 结果
     */
    public int deleteTRelServiceSubjectById(Long id);

    /**
     * 通过主题代码 查询主题事项关联列表
     *
     * @param subjectCode 主题代码
     * @return 主题事项关联集合
     */
    public List<TRelServiceSubject> selectTRelServiceSubjectBySubjectCode(String subjectCode);

    /**
     * 批量新增主题事项关联
     *
     * @param tRelServiceSubjectList
     * @return
     */
    public int batchInsertTRelServiceSubject(List<TRelServiceSubject> tRelServiceSubjectList);
    
    /**
     * 批量新增主题表单关联
     *
     * @param tRelFormSubject
     * @return
     */
    public int batchInsertTRelFormSubject(TRelFormSubject tRelFormSubject);

    /**
     * 批量删除主题事项关联
     *
     * @param tRelServiceSubjectList
     * @return
     */
    public int batchDeleteTRelServiceSubject(List<TRelServiceSubject> tRelServiceSubjectList);
    
    /**
     * 批量删除主题表单关联
     *
     * @param tRelFormSubjectList
     * @return
     */
    public int batchDeleteTRelFormSubject(Long[] ids);


    /**
     * 查询主题事项关联
     *
     * @param tRelServiceSubject 主题关联事项实体
     * @return 主题事项关联
     */
    public TRelServiceSubject selectTRelServiceSubjectByServiceSubjectCode(TRelServiceSubject tRelServiceSubject);

    /**
     * 查询主题表单关联
     *
     * @param tRelServiceSubject 主题关联表单实体
     * @return 主题表单关联
     */
    public List<TRelFormSubject> selectTRelFormSubjectByServiceSubjectCode(String subjectCode);
    public List<TRelFormSubject> selectlistExcludeFormByServiceSubjectCode(Map<String,Object> resultmap);
    
    /**
     * 删除主题的对应事项主题关联关系
     * @return
     */
    public int deleteTRelServiceSubjectBySubjectCode(Map<String,Object> map);
    /**
     * 修改主题表单关联
     *
     * @param tRelServiceSubject 主题表单关联
     * @return 结果
     */
    public int updateTRelFormSubject(TRelFormSubject tRelFormSubject);
    
    /**
     * 通过id 查询表单key
     * @param ids
     */
    List<String> getFormKeyByIds(Long[] ids);
	
//    Integer count(String formKey);
//
//    int updateByFormKey(TRelFormSubject tRelFormSubject);


}
